<template>
  <div class="app-container">
    <el-table
      :data="list"
      style="width: 100%">

      <!-- label: 表头文字、prop: 对应json数据里面的属性-->
      <el-table-column
        label="收派标准名称"
        prop="name"
        width="180">
      </el-table-column>

      <el-table-column
        label="最小重量"
        prop="minWeight"
        width="180">
      </el-table-column>

      <el-table-column
        label="操作时间"
        prop="operateTime"
        >
        <template slot-scope="scope">
          <span>{{ scope.row.operateTime | parseTime('{y}-{m}-{d} {h}:{i}') }}</span>
        </template>
      </el-table-column>
    </el-table>
  </div>
</template>

  <script>
  import { fetchStanList } from '@/api/standard'


    export default {
      data() {
        return {
        }
      },

      created() {
        // 页面创建的时候，去加载文章列表
        this.getList()
      },

      methods: {
        // 加载文章列表
        getList() {
          this.listLoading = true

          // 发送http请求，获取数据
          fetchList(this.listQuery).then(response => {
            this.list = response.data.items
            this.total = response.data.total
            this.listLoading = false
          })
        }
      }
    }
  </script>